const { defineConfig } = require('@vue/cli-service');  

module.exports = defineConfig({  
  transpileDependencies: true,  
  lintOnSave: false,   
  chainWebpack: (config) => {  
    config.plugin('define').tap((definitions) => {  
      Object.assign(definitions[0], {  
        __VUE_OPTIONS_API__: 'true',  
        __VUE_PROD_DEVTOOLS__: 'false',  
        __VUE_PROD_HYDRATION_MISMATCH_DETAILS__: 'false',  
      });  
      return definitions;  
    });  
  },  
  devServer: {  
    proxy: {  
      '/api': {  
        target: 'http://localhost:5084', // 使用与后端一致的地址  
        changeOrigin: true, // 更改源  
        secure: false, // Disable SSL for HTTP, can be true for HTTPS  
        pathRewrite: { '^/api': '/api' }, // 可选设置以保持路径一致性  
      },  
    },  
    client:{
     overlay:false
    } ,
  },  
});